[//OH HAI! I CAN HAZ LASSO?


	$head_insert += '<script type="text/javascript" src="/Assets/jquery/jquery.thickbox/thickbox-compressed.js"></script>';
	$head_insert += '<link rel="stylesheet" href="/Assets/jquery/jquery.thickbox/thickbox.css" type="text/css" media="screen" >';
	
	!(response_path)->endswith('Photos/') ? var('path' = var('pathTo_Level_'+(($levels->size)-1))) | var('path' = response_path);

]
<div id="gallery">
		<div id="gallery-thumbs">

[//HAI! I CAN HAZ LASSO?
	
		var('counter'=0);
		
		local('a_gallery' = $thisLevel_name);
		var('this_gallery'=#a_gallery);
		$this_gallery->replace('_and_', '&nbsp&amp;&nbsp;');
		$this_gallery->replace('~per-cent~', '%');
		$this_gallery->replace('~', '&rsquo;');
		$this_gallery->replace('__', ' / ');
		$this_gallery->replace('_', ' ');
		$this_gallery->removetrailing('/');
		
		var('listing' = file_ListDirectory('/Assets/userfiles/Image' $path ));
		iterate($listing, local('a_file'));
				var('x'=#a_file);
				$x->replace('_thumb.jpg', '_');
				$x->replace('_and_', '&nbsp&amp;&nbsp;');
				$x->replace('~per-cent~', '%');
				$x->replace('~', '&rsquo;');
				$x->replace('__', ' / ');
				$x->replace('--', ': ');
				$x->replace('_', ' ');
				$x->removetrailing('/');
				iterate($x, local('char'));
						#char->isDigit ? $x->remove(loop_count, loop_count);
						loop_abort;
				/iterate;
				if(#a_file->contains('_thumb'));
					var('y'=#a_file);
					$y->contains('.DS_') ? (loop_continue);
					'

						<a href="/Assets/userfiles/Image' $path ($y->replace('_thumb','')&) '" title="'$this_gallery ': '$x'" class="thickbox" >
						<img src="/Assets/userfiles/Image' $path #a_file'" width="75" height="75" alt=""></a>
						';
						//$counter % 6 != 0 ?  '' | '<br>' ($counter = 0);
				/if;
						
		/iterate;
		

				]
				
</div></div>
